<div class="input-group" ng-class="{'has-error': controller.isInvalid}">

  <input type="text" class="form-control"
         ng-model="controller.valueString"></input>

</div>

<div class="has-error" ng-if="controller.isInvalid">
  <span class="help-block">
    Expected format is [number][unit] where unit may be "s" for seconds, "m" for minutes, "h" for hours, "d" for days or "w" for weeks.
  </span>
</div>
